package com.example.zq;

import org.springframework.beans.factory.annotation.Value;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author : Zhang Qi
 * @date : 2019/11/12
 */
@RestController
public class HelloController {
  @Value("${server.port}")
  Integer port;

  @GetMapping("/hello")
  public String hello(String name){
    return "[from "+port+"]Hello,"+name+"!";
  }
}
